package com.vip.shopservice.shop.service.impl;

import com.vip.shopbase.Service.impl.GenericManagerImpl;
import com.vip.shopdao.admin.dao.UserDao;
import com.vip.shopdao.shop.dao.ShopDao;
import com.vip.shopdao.shop.domain.Shop;
import com.vip.shopservice.shop.service.ShopManager;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Classname ShopManageeImpl
 * @Description TODO
 */
@Service
public class ShopManageeImpl  extends GenericManagerImpl<Shop,Long> implements ShopManager, InitializingBean {
    ShopDao shopDao;

    @Autowired
    public void setUserDao(ShopDao shopDao){
        this.shopDao = shopDao;
        this.dao = this.shopDao;
    }

    @Override
    public void afterPropertiesSet() throws Exception {

    }

    @Override
    public Shop findByname(String name) {
        return shopDao.findShopByName(name);
    }
}
